When an electronic device is operated in an environment in which a noise is generated, the noise may adversely affect an operation of the electronic device. Therefore, a digital filter for removing noises is used in some cases (see, for example, Patent Literature 1). For example, an input unit of a sequencer takes in an input signal from a device such as a switch and a sensor through the digital filter.
However, the digital filter cannot detect presence or absence of a noise nor a noise level, although the digital filter can remove a noise. Information such as the presence or absence of a noise and the noise level is useful for identifying a source of noises, for example, and it is desirable to obtain such information.
Patent Literature 2 discloses a motor control device. The motor control device is provided with an inverter circuit and a current detection device that detects three-phase alternating-current output currents of the inverter circuit. A clock signal and a data signal of an AD converter are input to the current detection device. Then, the number of clocks in a certain period of time is measured to detect a noise level.